<extend name="work/base"/>
<block name="content">
    <table class="layui-table text-center" id="list" lay-filter="list" list-url="{:url('lists')}"
           edit-url="{:url('info')}" assigned-url="{:url('editcategory')}" del-url="{:url('delete')}"
           delinfo-url="{:url('delete')}"></table>
</block>

<block name="script">

    <script type="text/html" id="barDemo">
        <a class="layui-btn  layui-btn-xs " lay-event="edit"><i class="fa fa-pencil"></i> 查看记录</a>
    </script>
    <script type="text/javascript">
        layui.use(['element', 'table', 'form'], function () {
            var table = layui.table
                , form = layui.form;
            table.render({
                elem: '#list'
                , url: "{:Url('lists')}"
                , page: true
                , loading: true
                ,limit:20
                , cols: [[
                     {field: 'c_time',  width: 180,title: '时间'}
                    , {field: 'info', title: '内容'}
                    , {fixed: 'right', width: 100, title: '操作', toolbar: '#barDemo'}
                ]]
            });

        });
    </script>
</block>
